/************************************************************
https://anotherssisframework.codeplex.com

Copyright (c) 2014, Allen J. Zyck <sql.architect@outlook.com>

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated 
documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights 
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons
 to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the 
Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, 
INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE 
AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, 
DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

************************************************************/

/***********
File: Load_SSIS_Configuration_Table.sql

Description:
This is a SQL script to load the SSIS configuration data into the SSIS_Configurations table. 
Either in this script or after loading, you will need to edit the ConfiguredValue field
to the values specific to your environment.
***********/


USE <database, sysname, DWConfig>
GO

INSERT [dbo].[SSIS_Configurations] ([ConfigurationFilter], [ConfiguredValue], [PackagePath], [ConfiguredValueType]) VALUES (N'PasswordDBInstance', N'localhost', N'\Package.Connections[Passwords].Properties[ServerName]', N'String')
INSERT [dbo].[SSIS_Configurations] ([ConfigurationFilter], [ConfiguredValue], [PackagePath], [ConfiguredValueType]) VALUES (N'PasswordDB', N'DWPassword', N'\Package.Connections[Passwords].Properties[InitialCatalog]', N'String')
INSERT [dbo].[SSIS_Configurations] ([ConfigurationFilter], [ConfiguredValue], [PackagePath], [ConfiguredValueType]) VALUES (N'SMTPServer', N'localhost', N'\Package.Connections[SMTP].Properties[SmtpServer]', N'String')
INSERT [dbo].[SSIS_Configurations] ([ConfigurationFilter], [ConfiguredValue], [PackagePath], [ConfiguredValueType]) VALUES (N'Deleteme', N'SELECT CAST(1 AS INT) AS DummyVariable', N'\Package\Data Processing\Data Flow Task.Properties[[ADO NET ODBC Source].[SqlCommand]]', N'String')
INSERT [dbo].[SSIS_Configurations] ([ConfigurationFilter], [ConfiguredValue], [PackagePath], [ConfiguredValueType]) VALUES (N'TargetDWInstance', N'localhost', N'\Package.Connections[DataWarehouse].Properties[ServerName]', N'String')
INSERT [dbo].[SSIS_Configurations] ([ConfigurationFilter], [ConfiguredValue], [PackagePath], [ConfiguredValueType]) VALUES (N'StagingDBInstance', N'localhost', N'\Package.Connections[Staging].Properties[ServerName]', N'String')
INSERT [dbo].[SSIS_Configurations] ([ConfigurationFilter], [ConfiguredValue], [PackagePath], [ConfiguredValueType]) VALUES (N'StagingDB', N'DWStaging', N'\Package.Connections[Staging].Properties[InitialCatalog]', N'String')
INSERT [dbo].[SSIS_Configurations] ([ConfigurationFilter], [ConfiguredValue], [PackagePath], [ConfiguredValueType]) VALUES (N'HistoryDBInstance', N'localhost', N'\Package.Connections[History].Properties[ServerName]', N'String')
INSERT [dbo].[SSIS_Configurations] ([ConfigurationFilter], [ConfiguredValue], [PackagePath], [ConfiguredValueType]) VALUES (N'HistoryDB', N'DWStaging', N'\Package.Connections[History].Properties[InitialCatalog]', N'String')
INSERT [dbo].[SSIS_Configurations] ([ConfigurationFilter], [ConfiguredValue], [PackagePath], [ConfiguredValueType]) VALUES (N'DW Target DB', N'DataWarehouse', N'\Package.Connections[DataWarehouse].Properties[InitialCatalog]', N'String')
INSERT [dbo].[SSIS_Configurations] ([ConfigurationFilter], [ConfiguredValue], [PackagePath], [ConfiguredValueType]) VALUES (N'SSAS Instance', N'localhost', N'\Package.Connections[SSAS].Properties[ServerName]', N'String')
INSERT [dbo].[SSIS_Configurations] ([ConfigurationFilter], [ConfiguredValue], [PackagePath], [ConfiguredValueType]) VALUES (N'SMTP Success From Account', N'etlserver@local.lab', N'\Package\Successful Loading Closeout\Send Success e-Mail.Properties[FromLine]', N'String')
INSERT [dbo].[SSIS_Configurations] ([ConfigurationFilter], [ConfiguredValue], [PackagePath], [ConfiguredValueType]) VALUES (N'SMTP Success To Account', N'SSISSuccess@local.lab', N'\Package\Successful Loading Closeout\Send Success e-Mail.Properties[ToLine]', N'String')
INSERT [dbo].[SSIS_Configurations] ([ConfigurationFilter], [ConfiguredValue], [PackagePath], [ConfiguredValueType]) VALUES (N'SSAS DB', N'Adventure Works DW 2008R2', N'\Package.Connections[SSAS].Properties[InitialCatalog]', N'String')
INSERT [dbo].[SSIS_Configurations] ([ConfigurationFilter], [ConfiguredValue], [PackagePath], [ConfiguredValueType]) VALUES (N'SMTP Fail From Account', N'etlserver@local.lab', N'\Package\Setup\Failed Connection Mail Notification.Properties[FromLine]', N'String')
INSERT [dbo].[SSIS_Configurations] ([ConfigurationFilter], [ConfiguredValue], [PackagePath], [ConfiguredValueType]) VALUES (N'SMTP Fail From Account', N'etlserver@local.lab', N'\Package\Setup\Error Getting Lineage.Properties[FromLine]', N'String')
INSERT [dbo].[SSIS_Configurations] ([ConfigurationFilter], [ConfiguredValue], [PackagePath], [ConfiguredValueType]) VALUES (N'SMTP Fail From Account', N'etlserver@local.lab', N'\Package\Failure Loading Closeout\Send Failure e-Mail.Properties[FromLine]', N'String')
INSERT [dbo].[SSIS_Configurations] ([ConfigurationFilter], [ConfiguredValue], [PackagePath], [ConfiguredValueType]) VALUES (N'SMTP Failure To Account', N'SSISFailure@local.lab', N'\Package\Setup\Failed Connection Mail Notification.Properties[ToLine]', N'String')
INSERT [dbo].[SSIS_Configurations] ([ConfigurationFilter], [ConfiguredValue], [PackagePath], [ConfiguredValueType]) VALUES (N'SMTP Failure To Account', N'SSISFailure@local.lab', N'\Package\Setup\Error Getting Lineage.Properties[ToLine]', N'String')
INSERT [dbo].[SSIS_Configurations] ([ConfigurationFilter], [ConfiguredValue], [PackagePath], [ConfiguredValueType]) VALUES (N'SMTP Failure To Account', N'SSISFailure@local.lab', N'\Package\Failure Loading Closeout\Send Failure e-Mail.Properties[ToLine]', N'String')

